import request from '../util/request.js' //引入request实例

//添加管理员的请求
export const addAdminRequest = (data)=>{
    return request.post("/addAdmin", data)
}


//查询管理员的请求
export const adminListRequest = ()=>{
    return request.get("/adminList")
}

//删除管理员请求
export const deleteAdminRequest = (adminName)=>{
    return request.delete("/deleteAdmin",{
        params: {
            adminName
        }
    })
}

//登录请求
export const loginRequest = (data) => {
    return request.post("/login", data)
}